import java.util.Scanner;

public class Bits_of_integers {
    public static void main(String[] args) {
        Scanner sc =new Scanner(System.in);
        int number=sc.nextInt();
        while(number!=0){
            System.out.println(number%10);
            number/=10;
        }
    }
}
